// 产品相关配置
function createMoneyOptions() {
  const options = [500, 1000, 2000, 3000, 4000, 5000, 6000, 7000, 8000, 9000, 10000, 15000, 20000, 25000, 30000, 40000, 50000, 100000]

  const ary = options.map(item => ({
    label: `${item}元`,
    value: item,
  }))
  ary.unshift({
    label: '不限',
    value: '',
  })
  return ary
}

function createDateOptions() {
  const options = ['1天', '7天', '1个月', '3个月', '6个月', '12个月', '24个月', '36个月', '3年以上']
  const ary = options.map((item, index) => ({
    label: item,
    value: index + 1,
  }))
  ary.unshift({
    label: '不限',
    value: '',
  })
  return ary
}

function createRepayType() {
  const options = ['等额本息', '等额本金', '到期还款', '分期还款', '先息后本', '自由还款', '随借随还']
  const ary = options.map((item, index) => ({
    label: item,
    value: index + 1,
  }))
  ary.unshift({
    label: '不限',
    value: '',
  })
  return ary
}

export default {
  dateOptions: createDateOptions(),
  moneyOptions: createMoneyOptions(),
  repayTypeOptions: createRepayType(),
  cardOptions: [
    { label: '不限', value: '' },
    { label: '有信用卡', value: 1 },
    { label: '无信用卡', value: 0 },
  ],
  orderOptions: [
    { label: '不限', value: '' },
    { label: '贷款成功率', value: 1 },
    { label: '放贷速度', value: 2 },
  ],
}
